package com.wuseguang.springcloud.dao.repository;

import com.wuseguang.springcloud.entity.MeMoralEducation;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

public interface MeMoralEducationRepository extends JpaRepository<MeMoralEducation,Integer> {

    @Query(value = "select * from me_moral_education where school_id=?1 ORDER BY id desc",nativeQuery = true)
    List<MeMoralEducation> findBySchoolId(Integer id);
}
